package org.peterbjornx.gamestate;

import org.peterbjornx.Client;

import java.awt.event.KeyEvent;
import java.awt.event.MouseEvent;
import java.awt.*;

/**
 * Created by IntelliJ IDEA.
 * User: PeterbjornX
 * Date: Apr 9, 2009
 * Time: 8:17:47 PM
 * Displays a loading message
 */
public class LoadingGameState extends GameState {
    public LoadingGameState(Client clientinstance) {
        super(clientinstance);
    }

    public void paint(Graphics g){
        myClient.drawtitleback(g);
        String text = "Loading, please wait...";
        int x = 7;
        int y = 27;
        int sw = (int) g.getFontMetrics().getStringBounds(text,g).getWidth() + 6;
        g.setColor(Color.black);
        g.fillRect(x,y,sw,g.getFontMetrics().getHeight()+5);
        g.setColor(Color.white);
        g.drawRect(x,y,sw,g.getFontMetrics().getHeight()+5);
        g.drawString(text,x+3,(g.getFontMetrics().getHeight())+y);
    }

    public void notifyloaded() {
        
    }

    public void addMessage(String s) {
        //To change body of implemented methods use File | Settings | File Templates.
    }

    public void keyTyped(KeyEvent e) {
        //To change body of implemented methods use File | Settings | File Templates.
    }

    public void keyPressed(KeyEvent e) {
        //To change body of implemented methods use File | Settings | File Templates.
    }

    public void keyReleased(KeyEvent e) {
        //To change body of implemented methods use File | Settings | File Templates.
    }

    public void mouseClicked(MouseEvent e) {
        //To change body of implemented methods use File | Settings | File Templates.
    }

    public void mousePressed(MouseEvent e) {
        //To change body of implemented methods use File | Settings | File Templates.
    }

    public void mouseReleased(MouseEvent e) {
        //To change body of implemented methods use File | Settings | File Templates.
    }

    public void mouseEntered(MouseEvent e) {
        //To change body of implemented methods use File | Settings | File Templates.
    }

    public void mouseExited(MouseEvent e) {
        //To change body of implemented methods use File | Settings | File Templates.
    }
}
